Add patches from upstream to build with system gtk-doc again
authorSimon McVittie <smcv@debian.org>
Mon, 12 Oct 2020 09:38:56 +0000 (10:38 +0100)
committerSimon McVittie <smcv@debian.org>
Mon, 12 Oct 2020 09:38:56 +0000 (10:38 +0100)
debian/patches/Require-gtk-doc-1.33.patch [new file with mode: 0644]
debian/patches/build-Move-the-gtk-doc-dep-to-the-toplevel.patch [new file with mode: 0644]
debian/patches/series [new file with mode: 0644]

diff --git a/debian/patches/Require-gtk-doc-1.33.patch b/debian/patches/Require-gtk-doc-1.33.patch
new file mode 100644 (file)
index 0000000..9a7a58f
--- /dev/null
@@ -0,0 +1,25 @@
+From: Matthias Clasen <mclasen@redhat.com>
+Date: Thu, 1 Oct 2020 15:08:50 -0400
+Subject: Require gtk-doc 1.33
+
+We'll hopefully get a gtk-doc release out with that
+version number soon.
+
+Origin: upstream, 3.99.3, commit:ffb51b6888f9b199f31434cfeca89203130471c7
+---
+ meson.build | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/meson.build b/meson.build
+index 019b608..4476488 100644
+--- a/meson.build
++++ b/meson.build
+@@ -382,7 +382,7 @@ graphene_dep   = dependency('graphene-gobject-1.0', version: graphene_req,
+                             fallback: ['graphene', 'graphene_dep'])
+ iso_codes_dep  = dependency('iso-codes', required: false)
+-gtk_doc_dep    = dependency('gtk-doc', version: '>=1.99',
++gtk_doc_dep    = dependency('gtk-doc', version: '>=1.33',
+                             fallback: ['gtk-doc', 'dummy_dep'],
+                             default_options: ['tests=false', 'yelp_manual=false'],
+                             required: get_option('gtk_doc'))
diff --git a/debian/patches/build-Move-the-gtk-doc-dep-to-the-toplevel.patch b/debian/patches/build-Move-the-gtk-doc-dep-to-the-toplevel.patch
new file mode 100644 (file)
index 0000000..24f7f12
--- /dev/null
@@ -0,0 +1,52 @@
+From: Matthias Clasen <mclasen@redhat.com>
+Date: Fri, 4 Sep 2020 09:52:37 -0400
+Subject: build: Move the gtk-doc dep to the toplevel
+
+We want to include the gtk-doc subproject in release
+tarballs, using --include-subprojects, but that only
+works if we've actually built the subproject. And
+enabling gtk-doc for dist builds is problematic -
+it tends to break meson dist.
+
+So declare the gtk-doc dependency independent of
+-Dgtk_doc, and use --force-fallback-for for it.
+
+Origin: upstream, 3.99.2, commit:a8eae7afaa8560b8aa949b2de14f4da0027af42b
+---
+ docs/reference/meson.build | 6 ------
+ meson.build                | 5 +++++
+ 2 files changed, 5 insertions(+), 6 deletions(-)
+
+diff --git a/docs/reference/meson.build b/docs/reference/meson.build
+index 905af97..7652501 100644
+--- a/docs/reference/meson.build
++++ b/docs/reference/meson.build
+@@ -3,12 +3,6 @@ if get_option('gtk_doc')
+     error('Building the GTK documentation requires Meson 0.52.0')
+   endif
+-  # Use gtk-doc as a sub-project from the gtk-doc-for-gtk4 branch
+-  # for the time being
+-  dependency('gtk-doc', version: '>=1.99',
+-    fallback: ['gtk-doc', 'dummy_dep'],
+-    default_options: ['tests=false', 'yelp_manual=false'])
+-
+   glib_prefix = dependency('glib-2.0').get_pkgconfig_variable('prefix')
+   glib_docpath = join_paths(glib_prefix, 'share', 'gtk-doc', 'html')
+diff --git a/meson.build b/meson.build
+index 5ad8508..019b608 100644
+--- a/meson.build
++++ b/meson.build
+@@ -382,6 +382,11 @@ graphene_dep   = dependency('graphene-gobject-1.0', version: graphene_req,
+                             fallback: ['graphene', 'graphene_dep'])
+ iso_codes_dep  = dependency('iso-codes', required: false)
++gtk_doc_dep    = dependency('gtk-doc', version: '>=1.99',
++                            fallback: ['gtk-doc', 'dummy_dep'],
++                            default_options: ['tests=false', 'yelp_manual=false'],
++                            required: get_option('gtk_doc'))
++
+ fontconfig_dep = [] # only used in x11 backend
+ if os_win32
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644 (file)
index 0000000..12a7e9f
--- /dev/null
@@ -0,0 +1,2 @@
+build-Move-the-gtk-doc-dep-to-the-toplevel.patch
+Require-gtk-doc-1.33.patch